/*
 * @Author: LBH 1336709799@qq.com
 * @Date: 2024-12-09 09:13:20
 * @LastEditors: LBH 1336709799@qq.com
 * @LastEditTime: 2024-12-12 22:31:54
 * @FilePath: \hm-admin\src\apis\user.ts
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import type { LoginParams, Profile } from "@/types/user";
import { request } from "@/utils/reuqest";

export const loginAPI = (data:LoginParams) =>{
    return request<{token:string}>('/park/login','POST',data)
}

/**
 * @description: 获取用户信息
 * @param {*} data {}
 * @return {*} promise
 */
export const getProfileAPI = () => {
  return request<Profile>('/park/user/profile')
}